import React,{JSX,ReactNode} from 'react';
import { View,StyleSheet } from 'react-native';
import { normalize } from '../../utils/adapter';


type Props = {
    children:ReactNode,
    width?:number,
    Y?:number
}

function Card({children,Y}:Props):JSX.Element {

    return (
        <View style={[styles.card,{transform:[{translateY:Y ?  Y as number : 0}]}]}>
            {children}
        </View>
    );
}



const styles = StyleSheet.create({
    card:{
        marginHorizontal:normalize(12),
        backgroundColor:'#fff',
        borderRadius:normalize(10),
    },
});

export default Card;
